package com.ease.platform.authorization.vo;

import java.io.Serializable;

public class AuthorizationResult implements Serializable {

	/**
	 *
	 */
	private static final long serialVersionUID = 7247391954042702398L;

	private boolean authorized;

	private String unAuthorizedReason;

	public static boolean isAuthorized(AuthorizationResult authorizationResult) {
		return (null != authorizationResult && authorizationResult.isAuthorized());
	}

	/**
	 * @return the authorized
	 */
	public boolean isAuthorized() {
		return authorized;
	}

	/**
	 * @param authorized
	 *            the authorized to set
	 */
	public void setAuthorized(boolean authorized) {
		this.authorized = authorized;
	}

	public String getUnAuthorizedReason() {
		return unAuthorizedReason;
	}

	public void setUnAuthorizedReason(String unAuthorizedReason) {
		this.unAuthorizedReason = unAuthorizedReason;
	}

}
